{% if is_all!=1 %}
{% extends "frame.html" %}
{% block title %}内置函数测试{% endblock %}
{% endif %}

{% block body %}
{% if is_all!=1 %}
{% include "menu.html" %}
{% endif %}
<hr>
<h2>内置函数测试</h2>
upper({{hwd}}): {{ upper(hwd) }} <br>
lower({{hwd}}): {{ lower(hwd) }} <br>
range()[len(4)]:
[
{% for i in range(4) %}
{{ loop.index1 }}
{% endfor %}
]
<br>
length(guests): {{ length(guests) }} <br>
first(guests): {{ first(guests) }} <br>
last(guests): {{ last(guests) }} <br>
sort([3,2,1]): {{ sort([3,2,1]) }} <br>
round(3.1415, 3): {{ round(3.1415, 3) }}  <br>
odd(42): {{ odd(42) }} <br>
even(42): {{even(42)}} <br>
divisibleBy(42, 7): {{divisibleBy(42, 7)}} <br>
max([1, 2, 3]): {{max([1, 2, 3])}} <br>
int("2"): {{ int("2") }} <br>
float("1.8"): {{float("1.8")}} <br>
default(user.name, "张三"): {{default(user.name, "张三")}}  <br>
default(name233, "张三"): {{default(name233, "张三")}}  <br>
exists("guests"): {{exists("guests")}}  <br>
exists("city"): {{exists("city")}}  <br>
existsIn(user, "name"): {{existsIn(user, "name") }}<br>
existsIn(user, "name23"): {{existsIn(user, "name23") }}<br>
isString(user.name): {{isString(user.name)}}<br>
isString(user.age): {{isString(user.age)}}<br>
isArray(guests): {{isArray(guests)}}<br>


{% endblock %}
